#ifndef TC_EXSTRING_HH
#define TC_EXSTRING_HH

/** \file ExString.hh 
 * Declarations for the ExString class.
 *
 * (C) Copyright  Semih Cemiloglu
 * All rights reserved, see COPYRIGHT file for details.
 *
 * $Id: ExIf.hh 117 2006-06-19 06:49:41Z semihc $
 *
 *
 */

#include <string>
#include "Ex.hh"


namespace TC {


/**
 * A 'String' exception class which contains embedded
 * string to build description incrementally or dynamically.
 */
struct ExString : public ExSimple
{
  // CREATORS
  ExString(const std::string& dstr,
           const int reason = 0, 
           const char* file = 0, int lineno = 0, const char* func = 0) :
      ExSimple(0,reason,file,lineno,func), m_dstr(dstr) {}
  virtual ~ExString() throw() {}
  
  // ACCESSORS
  virtual void print(std::ostream&) const;
  virtual const char* what() const throw()
  { return m_dstr.c_str(); }  
    
  // MEMBERS
  std::string m_dstr;
};


} // end namespace




#endif /* Include guard */
